#coding=utf-8
import os.path
import shutil

def copy_file(source_file, target_path):
    if not os.path.exists(source_file):
        print "ERROR:%s不存在" % source_file

    shutil.copy(source_file, target_path)


if __name__ == '__main__':

    need_copy_files = ['Contract/competition.xml', 'Contract/secret.xml']

    target_dirs = ['Contract/catering/', 'Contract/internet/', 'Contract/culture/', 'Contract/cloth/',
                   'Contract/education/', 'Contract/retail/', 'Contract/travel/', 'Contract/construction/',
                   'Contract/finance/', 'Contract/science/', 'Contract/humanResource/']

    for target_dir in target_dirs:
        for f in need_copy_files:
            copy_file(f, target_dir)
